#include "drve_led.h"
#include "drv_systick.h"
#include "drv_beep.h"
#include "drv_key.h"
 static uint8_t key_status=0;
int main (void)
{    
	drv_systick_init(168);
	drve_led_int();
	drv_key_int();
	beep_init();
	
	while(1)
	{
	 if(drv_get_key())
	 	{
	 	  key_status=~key_status;
	 	}
	 if(key_status)
	 	{
	 	 beep_on();
		 drve_led_open();
      //drve_led_open();
	 // drv_systick_ms(10000);
	  //drve_led_close();
	 // drv_systick_ms(10000);
	 	}
	else
	{
		beep_off();
		drve_led_close();
	}
	}
}
